<?php
session_start();
?>


<?php
$username = $_SESSION['username'];
$role = $_SESSION['role'];
if($username==null || $username== ""|| $username == "")
{
	header('Location: http://172.26.195.159/checklist/php/logout.php');
}
?>

<html>

<head>

<style>


A.tip {     color:blue; }
A.tip:hover {     background-color:orange;color:black } 





ul.svertical{
width: 200px; /* width of menu */
overflow: auto;
background: black; /* background of menu */
margin: 0;
padding: 0;
padding-top: 7px; /* top padding */
list-style-type: none;
}

ul.svertical li{
text-align: right; /* right align menu links */
}

ul.svertical li a{
position: relative;
display: inline-block;
text-indent: 5px;
overflow: hidden;
background: rgb(127, 201, 200); /* initial background color of links */
font: bold 16px Germand;
text-decoration: none;
padding: 5px;
margin-bottom: 7px; /* spacing between links */
color: black;
-moz-box-shadow: inset -7px 0 5px rgba(114,114,114, 0.8); /* inner right shadow added to each link */
-webkit-box-shadow: inset -7px 0 5px rgba(114,114,114, 0.8);
box-shadow: inset -7px 0 5px rgba(114,114,114, 0.8);
-moz-transition: all 0.2s ease-in-out; /* CSS3 transition of hover properties */
-webkit-transition: all 0.2s ease-in-out;
-o-transition: all 0.2s ease-in-out;
-ms-transition: all 0.2s ease-in-out;
transition: all 0.2s ease-in-out;
}

ul.svertical li a:hover{
padding-right: 30px; /* add right padding to expand link horizontally to the left */
color: black;
background: rgb(153,249,75);
-moz-box-shadow: inset -3px 0 2px rgba(114,114,114, 0.8); /* contract inner right shadow */
-webkit-box-shadow: inset -3px 0 5px rgba(114,114,114, 0.8);
box-shadow: inset -3px 0 5px rgba(114,114,114, 0.8);
}

ul.svertical li a:before{ /* CSS generated content: slanted right edge */
content: "";
position: absolute;
left: 0;
top: 0;
border-style: solid; 
border-width: 70px 0 0 20px; /* Play around with 1st and 4th value to change slant degree */
border-color: transparent transparent transparent black; /* change black to match the background color of the menu UL */

}

</style>


<title>
Page Title
</title>
</head>
<!-- background-color:Lime; -->

<body bgcolor="#C9C299">

<div align="top" style="width:930px;height:50px;border:solid;border-width:1;border-color:Silver;border-style:Double;">

<h2 style="text-align:center;position:absolute;center:0px;width:1020px;font:36px bold calibri;">iVSE WebChecklist v1.0&beta;1</h2>
</br>
<b style="align:right"> Welcome <?php echo "".$_SESSION['fullname']; ?><b></br>
<a href="logout.php" class="tip">Logout</a></br>
<a href="changePassword.php" class="tip">Change Password</a>




</div>



<div style="width:160px;float:left;background:#C9BE62;">

<center><h2 style="font:bold 15px MS Sans serif , Georgia;font-size:40px;">Menu</h2></center>

	<ul class="svertical">
    <li><a href="crDetails.php">Create Checklist</a></li>
    <li><a href="bin.php">Check Status of my CR</a></li>
	<li><a href="verifyChecklist.php" alt="Check all status to be verified">Verify the Checklist</a></li>
	<?php
	
	if($role=='PM' || $role=='PL' || $role=='DP' || $username == 'xgaupru')
	{
	?>
	
	<li><a href="generateReport.php">Generate Report</a></li>
	<li><a href="processStatusOfACr.php" alt="Check status of all CRs">Check Status of all CR</a></li>
	
	
	<?php
	}
	if($username=='xgaupru')
	{
	?>
	<li><a href="processNotification.php">Notifications</a></li>
	<li><a href="customisedMailer.html">Mailer Application</a></li>
	<li><a href="./preparation/wordForm.php">Made Easy</a></li>
	<?php
	}
	?>
	<li><a href="feedback.php">Send Feedback</a></li>
	<li><a href="Internal_Code_review.ppt"><img src="./images/ppt_icon.gif" height=32 width=32/>Read Me</a></li>
	</ul>

</div>


<div style="width:720px;height:425px;float:left;background:#E18B6B;overflow:scroll">
<center>
<h2>Please make sure that when you fix/review/re-review any CR/feature code following comments should not be
repeated in future IDCEs.
</h2>
</center>

<table border="1" cellpadding="5px">




<tr><td>1</td><td class="bold">Divide by zero not handle. We must have this robustness check in all the domains
except kernel(with appropriate justification). If you are skipping this check intentionally make sure to
document it in the code/IDCE so that reviewer can evaluate if it is acceptable or not</td></tr>

<tr><td>2</td><td class="bold">Avoid memory allocation in very frequent scenarios to avoid memory fragmentation
and poor system performance. Instead allocate once in constructor and destroy in destructor or appropriate
methods based on code flow. This is the case when you allocate/deallocate memory for same structure
periodically.</td></tr>

<tr><td>3</td><td class="bold">STRLEN() function does not count NULL termination character '\0' and SIZEOF()
does count the null termination. So when you write any logic for string copy/manipulation make sure to
understand the difference between the two specially when you are checking boundary conditions.</td></tr>

<tr><td>4</td><td class="bold">Before allocating any memory and passing it's pointer by reference, first
understand that if the calling function is responsible for memory allocation or the caller. Any misunderstanding
will result into the memory leak. It also indicates poor understanding of the code flow.</td></tr>

<tr><td>5</td><td class="bold">Before checking any return value of a function, understand carefully what are the
possible return values of that function , for system calls read man pages carefully.</td></tr>

<tr><td>6</td><td class="bold">Before performing any operation on pointer, make sure to check for
NULL.(robustness check).  There may be some exception like singleton pattern etc. Document the exceptions in
code/IDCE for the reviewer evaluation.</td></tr>

<tr><td>7</td><td class="bold">Avoid using hard coded values in the program which can make your design non
extensible.</td></tr>

<tr><td>8</td><td class="bold">Always write portable code which is not compiler/OS dependent.</td></tr>

</table>

</div>


<div style="position:absolute;bottom:0;left:10;bottom: 10;z-index: 1;"><a href="mailto:gaurav.pruthi@tcs.com" class="tip">Contact Us</a></div> 
<div style="position:absolute;bottom:0;right:34;z-index: 1;"><a href="http://www.tcs.com" class="tip">&copy; Tata Consultancy Services Limited</a></div>

</body>
</html>





